import request from '@/utils/processRequest';

// 获取项目列表
export function getProgramList(data) {
  return request({
    url: '/budget/in/getProgramList',
    method: 'post',
    data
  });
}
// 获取指标列表(父节点)
export function getBudgetList(data) {
  return request({
    url: '/budget/in/getList',
    method: 'post',
    data
  });
}

// 获取指标列表后根据code获取指标列表
export function getBudgetByCode(data) {
  return request({
    url: '/budget/in/getByCode',
    method: 'post',
    data
  });
}

// 获取指标列表后根据code获取指标列表
export function inBudgetAdd(data) {
  return request({
    url: '/budget/in/add',
    method: 'post',
    data
  });
}

export function exportBudget(data) {
  return request({
    url: '/budget/in/export',
    method: 'post',
    responseType: 'blob',
    data
  });
}

export function delBudget(data) {
  return request({
    url: '/budget/in/del',
    method: 'post',
    data
  });
}

export function editBudget(data) {
  return request({
    url: '/budget/in/edit',
    method: 'post',
    data
  });
}
